prefer rte_waypt_ct() over waypoint_list.count().
authortsteven4 <13596209+tsteven4@users.noreply.github.com>
Thu, 25 Nov 2021 17:09:04 +0000 (10:09 -0700)
committertsteven4 <13596209+tsteven4@users.noreply.github.com>
Thu, 25 Nov 2021 17:09:04 +0000 (10:09 -0700)
this provides some insulation from the underlying WaypointList
container.

dmtlog.cc
mapsend.cc

index d37893d0f8cf8609819b6ea8aaa80ca4f95080b7..26166b465f7bdb1a777076ada1e107548af76458 100644 (file)
--- a/dmtlog.cc
+++ b/dmtlog.cc
@@ -699,7 +699,7 @@ write_header(const route_head* trk)
 
   int count = 0;
   if (trk != nullptr) {
-    count = trk->waypoint_list.count();
+    count = trk->rte_waypt_ct();
   }
   if (!trk || trk->rte_name.isEmpty()) {
     write_str("Name", fout);
index 61c761dce190efa0028a7ab74d966a30561bf6d7..ba26430f2bbff864807fe59c43a2bf815b422db9 100644 (file)
@@ -430,7 +430,7 @@ static void mapsend_track_hdr(const route_head* trk)
   gbfputpstr(tname, mapsend_file_out);
 
   /* total nodes (waypoints) this track */
-  int i = trk->waypoint_list.count();
+  int i = trk->rte_waypt_ct();
 
   gbfputint32(i, mapsend_file_out);